﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace TestTasks
{
    public class FibonacciProvider
    {
        public int GetNumber(uint n) 
        { 
            var a = 0;
            var b = 1;
            
            while (n > 0) checked
            {
                var c = a + b;
                a = b;
                b = c;
                n--;
            }

            return a;
        }
    }
}
